package com.skivingcloud.report.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.datatype.jsr310.deser.LocalDateTimeDeserializer;
import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateTimeSerializer;
import com.mybatisflex.annotation.Column;
import com.mybatisflex.annotation.Id;
import com.mybatisflex.annotation.Table;
import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.List;

import io.swagger.v3.oas.annotations.media.Schema;

/**
 * 数据集管理 实体类。
 *
 * @author skivingcloud
 * @since 2024-09-12
 */
@Schema(description = "数据集管理")
@Table("report_data_set")
public class ReportDataSet implements Serializable {

    private static final long serialVersionUID = 1L;

    @Id
    @Schema(description = "")
    private String id;

    /**
     * 数据集编码
     */
    @Schema(description = "数据集编码")
    private String setCode;

    /**
     * 数据集名称
     */
    @Schema(description = "数据集名称")
    private String setName;

    /**
     * 数据集描述
     */
    @Schema(description = "数据集描述")
    private String setDesc;

    /**
     * 数据源编码
     */
    @Schema(description = "数据源编码")
    private String sourceCode;

    /**
     * 动态查询sql或者接口中的请求体
     */
    @Schema(description = "动态查询sql或者接口中的请求体")
    private String dynSentence;

    /**
     * 结果案例
     */
    @Schema(description = "结果案例")
    private String caseResult;

    /**
     * 0--已禁用 1--已启用  DIC_NAME=ENABLE_FLAG
     */
    @Schema(description = "0--已禁用 1--已启用  DIC_NAME=ENABLE_FLAG")
    private String enableFlag;

    /**
     * 0--未删除 1--已删除 DIC_NAME=DELETE_FLAG
     */
    @Schema(description = "0--未删除 1--已删除 DIC_NAME=DELETE_FLAG")
    private String deleteFlag;

    /**
     * 创建人
     */
    @Schema(description = "创建人")
    private String createBy;

    /**
     * 创建时间
     */
    @Schema(description = "创建时间")
    @JsonDeserialize(using = LocalDateTimeDeserializer.class)
    @JsonSerialize(using = LocalDateTimeSerializer.class)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime createTime;

    /**
     * 更新人
     */
    @Schema(description = "更新人")
    private String updateBy;

    /**
     * 更新时间
     */
    @Schema(description = "更新时间")
    @JsonDeserialize(using = LocalDateTimeDeserializer.class)
    @JsonSerialize(using = LocalDateTimeSerializer.class)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime updateTime;

    @Schema(description = "")
    private Integer version;

    @Schema(description = "")
    private String setType;

    /**
     * 数据源名称
     */
    @Column(ignore = true)
    @Schema(description = "数据源名称")
    private String sourceName;
    /** 请求参数集合 */
    @Column(ignore = true)
    @Schema(description = "请求参数集合")
    private List<ReportDataSetParam> dataSetParamList;
    /** 数据转换集合 */
    @Column(ignore = true)
    @Schema(description = "数据转换集合")
    private List<ReportDataSetTransform> dataSetTransformList;

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getSetCode() {
        return setCode;
    }

    public void setSetCode(String setCode) {
        this.setCode = setCode;
    }

    public String getSetName() {
        return setName;
    }

    public void setSetName(String setName) {
        this.setName = setName;
    }

    public String getSetDesc() {
        return setDesc;
    }

    public void setSetDesc(String setDesc) {
        this.setDesc = setDesc;
    }

    public String getSourceCode() {
        return sourceCode;
    }

    public void setSourceCode(String sourceCode) {
        this.sourceCode = sourceCode;
    }

    public String getDynSentence() {
        return dynSentence;
    }

    public void setDynSentence(String dynSentence) {
        this.dynSentence = dynSentence;
    }

    public String getCaseResult() {
        return caseResult;
    }

    public void setCaseResult(String caseResult) {
        this.caseResult = caseResult;
    }

    public String getEnableFlag() {
        return enableFlag;
    }

    public void setEnableFlag(String enableFlag) {
        this.enableFlag = enableFlag;
    }

    public String getDeleteFlag() {
        return deleteFlag;
    }

    public void setDeleteFlag(String deleteFlag) {
        this.deleteFlag = deleteFlag;
    }

    public String getCreateBy() {
        return createBy;
    }

    public void setCreateBy(String createBy) {
        this.createBy = createBy;
    }

    public LocalDateTime getCreateTime() {
        return createTime;
    }

    public void setCreateTime(LocalDateTime createTime) {
        this.createTime = createTime;
    }

    public String getUpdateBy() {
        return updateBy;
    }

    public void setUpdateBy(String updateBy) {
        this.updateBy = updateBy;
    }

    public LocalDateTime getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(LocalDateTime updateTime) {
        this.updateTime = updateTime;
    }

    public Integer getVersion() {
        return version;
    }

    public void setVersion(Integer version) {
        this.version = version;
    }

    public String getSetType() {
        return setType;
    }

    public void setSetType(String setType) {
        this.setType = setType;
    }

    public String getSourceName() {
        return sourceName;
    }

    public void setSourceName(String sourceName) {
        this.sourceName = sourceName;
    }

    public List<ReportDataSetParam> getDataSetParamList() {
        return dataSetParamList;
    }

    public void setDataSetParamList(List<ReportDataSetParam> dataSetParamList) {
        this.dataSetParamList = dataSetParamList;
    }

    public List<ReportDataSetTransform> getDataSetTransformList() {
        return dataSetTransformList;
    }

    public void setDataSetTransformList(List<ReportDataSetTransform> dataSetTransformList) {
        this.dataSetTransformList = dataSetTransformList;
    }
}
